<!doctype html>
<html>
<head>
    <meta charset="utf-8" />
    <meta name="format-detection" content="telephone=no" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
	<meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="apple-mobile-web-app-status-bar-style" content="black" />
    <title>绑定手机号</title>
    <link rel="stylesheet" href="../mui/css/mui.min.css" type="text/css" />
    <link rel="stylesheet" href="../css/base.css" type="text/css" />
    <link rel="stylesheet" href="../css/style.css" type="text/css" />
</head>

<body class="bgc-fff">
<header class="mui-bar mui-bar-nav">
	<a class="mui-action-back"><i class="icon icon-back"></i></a>
	<h1 class="mui-title">绑定手机号</h1>
</header>
<div class="mui-content pb15">
	<div class="user-tel">当前手机号码是：188****9787</div>
	<ul class="c-list list-borb">
    	<li>
        	<div class="c-list-key w65">手机号</div>
        	<div class="c-list-info"><input type="tel" class="list-text" placeholder="请输入要绑定的手机号码" /></div>
        </li>
    	<li class="pr0">
        	<div class="c-list-key w65">验证码</div>
        	<div class="c-list-info"><input type="text" class="list-text" placeholder="请输入验证码" /></div>
        	<div class="c-list-key"><a href="javascript:;" class="getcode">获取验证码</a></div>
        </li>
    </ul>
    <div class="plr15 mt40">
    	<a href="javascript:;" class="c-btn c-btn-red" id="nameSave">提交</a>
    </div>
</div>
<script type="text/javascript" src="../js/jquery.min.js"></script>
<script type="text/javascript" src="../mui/js/mui.min.js"></script>
<script type="text/javascript" src="../js/base.js"></script>
<script type="text/javascript">
$(function(){
	//获取验证码
	$('.getcode').on('click',function(){
		var disable = $(this).hasClass('disable');
		if(!disable){
			$(this).addClass('disable');
			settime();
			myLayer.alert('验证码已发送');
		}
	});
});

var countdown=60;
function settime() { 
	if (countdown == 0) { 
		$('.getcode').html('重新获取').removeClass('disable'); 
		countdown = 60;
		return;
	} else {
		$('.getcode').html(countdown + 's后重试'); 
		countdown--; 
	} 
	setTimeout(function() { 
		settime();
	},1000) 
}
</script>
</body>
</html>